home *** CD-ROM | disk | FTP | other *** search
/ Unreal Tournament Game Programming for Teens / UnrealTournamentGameProgrammingForTeens.iso / Chapter Files / Chapter05 / CommandTriggerV2.txt next >
Encoding:
Text File  |  2006-10-11  |  741 b   |  22 lines

  1.     //=============================================================
  2.     // CommandTrigger.
  3.     //=============================================================
  4.     class CommandTrigger extends Trigger placeable;
  5.  
  6.        //#1 Scope of the class but visible outside
  7.        var (Message) public string StandUpMessage;
  8.        var (Message) public string CommandMessage;
  9.  
  10.        //#2 Scope of the class but visible only inside
  11.        var private string DefaultMessage;
  12.     
  13.        function PostBeginPlay(){
  14.          Super.PostBeginPlay();
  15.  
  16.          //#3 Scope of the function, which is also
  17.          // inside the scope of the class
  18.          DefaultMessage = "Move yet again:";   
  19.          Message = StandUpMessage;
  20.        }
  21.  
  22.